package org.jeecg.modules.meter.service.impl;


import org.jeecg.entity.meter.Meter;
import org.jeecg.entity.meter.MeterAccount;
import org.jeecg.modules.meter.mapper.MeterAccountMapper;
import org.jeecg.modules.meter.service.IMeterAccountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.List;

/**
 * @Description: 仪表账户表
 * @Author: jeecg-boot
 * @Date:   2020-12-01
 * @Version: V1.0
 */
@Service
public class MeterAccountServiceImpl extends ServiceImpl<MeterAccountMapper, MeterAccount> implements IMeterAccountService {

    @Autowired
    private MeterAccountMapper meterAccountMapper;

    @Override
    public void refreshReadTimeBatch(List<Meter> onlyReadTimeList) {
        meterAccountMapper.refreshReadTimeBatch(onlyReadTimeList);
    }

    @Override
    public void updateRepairRead(MeterAccount meterAccount) {
        meterAccountMapper.updateRepairRead(meterAccount);
    }

    @Override
    public MeterAccount getByMeterId(String meterId) {
        return meterAccountMapper.getByMeterId(meterId);
    }
}
